package com.smile.ye.data.entity;
import com.baomidou.mybatisplus.annotation.TableField;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
@Data
@AllArgsConstructor
@NoArgsConstructor
public class CartDetailEntity {
    String item;
    Integer num;
    Integer price;
    String title;
    @TableField("coverUrl")
    String coverUrl;

    @Override
    public boolean equals(Object obj){
        if(obj instanceof CartDetailEntity){
            CartDetailEntity o = (CartDetailEntity)obj;
            return(o.item.equals(item));
        }
            return false;
    }
    @Override
    public int hashCode() {
      return item.hashCode();
    }

}
